<div class="content-section introduction">
    <div>
        <span class="feature-title">Toolbar</span>
        <span>Toolbar is a grouping component for buttons and other content.</span>
    </div>
</div>

<div class="content-section implementation">
    <p-toolbar>
        <div class="ui-toolbar-group-left">
            <button pButton type="button" label="New" icon="fa-plus"></button>
            <button pButton type="button" label="Open" icon="fa-folder-open" class="ui-button-success"></button>
                
            <i class="fa fa-bars"></i>
            
            <p-splitButton label="Save" icon="fa-check" [model]="items" styleClass="ui-button-warning"></p-splitButton>
        </div>
        
        <div class="ui-toolbar-group-right">
            <button pButton type="button" icon="fa-search"></button>
            <button pButton type="button" icon="fa-refresh"></button>
            <button pButton type="button" icon="fa-trash" class="ui-button-danger"></button>
        </div>
   </p-toolbar>
</div>

<div class="content-section documentation">
    <p-tabView effect="fade">
        <p-tabPanel header="Documentation">
            <h3>Import</h3>
<pre>
<code class="language-typescript" pCode ngNonBindable>
import &#123;ToolbarModule&#125; from 'primeng/toolbar';
</code>
</pre>

            <h3>Getting Started</h3>
            <p>Toolbar is a container component defined using p-toolbar element. Left aligned content is placed inside a div 
            having .ui-toolbar-group-left class and similarly .ui-toolbar-group-right for right alignment.</p>
<pre>
<code class="language-markup" pCode ngNonBindable>
&lt;p-toolbar&gt;
    &lt;div class="ui-toolbar-group-left"&gt;
        &lt;button pButton type="button" label="New" icon="fa-plus"&gt;&lt;/button&gt;
        &lt;button pButton type="button" label="Open" icon="fa-folder-open"&gt;&lt;/button&gt;
            
        &lt;i class="fa fa-bars"&gt;&lt;/i&gt;
        
        &lt;p-splitButton label="Save" icon="fa-check" [model]="items"&gt;&lt;/p-splitButton&gt;
    &lt;/div&gt;
    
    &lt;div class="ui-toolbar-group-right"&gt;
        &lt;button pButton type="button" icon="fa-search"&gt;&lt;/button&gt;
        &lt;i class="fa fa-bars"&gt;&lt;/i&gt;
        &lt;button pButton type="button" icon="fa-refresh"&gt;&lt;/button&gt;
        &lt;button pButton type="button" icon="fa-trash"&gt;&lt;/button&gt;
    &lt;/div&gt;
&lt;/p-toolbar&gt;
</code>
</pre>
            
            <h3>Properties</h3>
            <div class="doc-tablewrapper">
                <table class="doc-table">
                    <thead>
                        <tr>
                            <th>Name</th>
                            <th>Type</th>
                            <th>Default</th>
                            <th>Description</th>
                        </tr>
                    </thead>
                    <tbody>
                        <tr>
                            <td>style</td>
                            <td>string</td>
                            <td>null</td>
                            <td>Inline style of the component.</td>
                        </tr>
                        <tr>
                            <td>styleClass</td>
                            <td>string</td>
                            <td>null</td>
                            <td>Style class of the component.</td>
                        </tr>
                    </tbody>
                </table>
            </div>

            <h3>Styling</h3>
            <p>Following is the list of structural style classes, for theming classes visit <a href="#" [routerLink]="['/theming']">theming page</a>.</p>
            <div class="doc-tablewrapper">
                <table class="doc-table">
                    <thead>
                        <tr>
                            <th>Name</th>
                            <th>Element</th>
                        </tr>
                    </thead>
                    <tbody>
                        <tr>
                            <td>ui-toolbar</td>
                            <td>Main container element.</td>
                        </tr>
                        <tr>
                            <td>ui-toolbar-group-left</td>
                            <td>Left content container.</td>
                        </tr>
                        <tr>
                            <td>ui-toolbar-group-right</td>
                            <td>Right content container.</td>
                        </tr>
                    </tbody>
                </table>
            </div>

            <h3>Dependencies</h3>
            <p>None.</p>
        </p-tabPanel>

        <p-tabPanel header="Source">
            <a href="https://github.com/primefaces/primeng/tree/master/src/app/showcase/components/toolbar" class="btn-viewsource" target="_blank">
                <i class="fa fa-github"></i>
                <span>View on GitHub</span>
            </a>
<pre>
<code class="language-markup" pCode ngNonBindable>
&lt;p-toolbar&gt;
    &lt;div class="ui-toolbar-group-left"&gt;
        &lt;button pButton type="button" label="New" icon="fa-plus"&gt;&lt;/button&gt;
        &lt;button pButton type="button" label="Open" icon="fa-folder-open" class="ui-button-success"&gt;&lt;/button&gt;
            
        &lt;i class="fa fa-bars"&gt;&lt;/i&gt;
        
        &lt;p-splitButton label="Save" icon="fa-check" (onClick)="save()" [model]="items" styleClass="ui-button-warning"&gt;&lt;/p-splitButton&gt;
    &lt;/div&gt;
    
    &lt;div class="ui-toolbar-group-right"&gt;
        &lt;button pButton type="button" icon="fa-search"&gt;&lt;/button&gt;
        &lt;button pButton type="button" icon="fa-refresh"&gt;&lt;/button&gt;
        &lt;button pButton type="button" icon="fa-trash" class="ui-button-danger"&gt;&lt;/button&gt;
    &lt;/div&gt;
&lt;/p-toolbar&gt;
</code>
</pre>
        </p-tabPanel>
    </p-tabView>
</div>